<!DOCTYPE html>
<html>
<head>
<meta charset="utf-8">
<link rel="stylesheet" href="../../static/layui/css/layui.css"
	media="all">
<link rel="stylesheet" type="text/css"
	href="http://www.jq22.com/jquery/font-awesome.4.6.0.css">
<link rel="stylesheet" href="../../static/modules/common.css">
<!-- tree -->
<link rel="stylesheet" href="../../static/tree/zTreeStyle.css" type="text/css">
<link rel="stylesheet" href="../../static/tree/metroStyle/metroStyle.css" type="text/css">
<style type="text/css">
	#tree_div{
		   margin: 100px 40%;
	}
	#tree_div .layui-btn{
		margin-left: 16px !important;
	}
</style>
</head>
<body>
	<div id="data_div" class="main ">
		<fieldset class="layui-elem-field layui-field-title site-title">
			<legend>
				<a name="use"> 遵义应急救灾系统角色列表 </a>
			</legend>
		</fieldset>

		<div class="layui-btn-group">
			<button class="layui-btn" id="add_btn">增加</button>
		</div>
		<table id="data_table"></table>
	</div>
	<!-- 添加 -->
	<div id="add_div" class="modal hide main">
		<button class="layui-btn layui-btn-sm layui-btn-normal cancel">
			<i class="layui-icon"> 返回</i>
		</button>
		<fieldset class="layui-elem-field layui-field-title site-title">
			<legend>
				<a name="use"> 添加角色 </a> 
			</legend>
		</fieldset>
		<div class="site-text site-block">
			<form id="add_form">
				<div class="layui-form-item">
					<label class="layui-form-label">角色名称</label>
					<div class="layui-input-inline">
						<input type="text" check="角色名称" name="name" placeholder="请输入角色名称"
							maxlength="16" autocomplete="off" class="layui-input">
					</div>
					<div class="layui-form-mid layui-word-aux">*</div>
				</div>
				<div class="layui-form-item">
					<label class="layui-form-label">类型</label>
					<div class="layui-input-inline">
						<input type="text" check="类型-int" name="type" placeholder="请输入类型"
							maxlength="8" autocomplete="off" class="layui-input">
					</div>
					<div class="layui-form-mid layui-word-aux">*</div>
				</div>
				<div class="layui-form-item">
					<label class="layui-form-label">描述</label>
					<div class="layui-input-inline">
						<textarea class="layui-textarea" name="description" maxlength="255"></textarea>
					</div>
					<div class="layui-form-mid layui-word-aux">*</div>
				</div>

				<div class="layui-form-item">
					<div class="layui-input-block">
						<button type="button" class="layui-btn active" id="submit_btn_a">立即提交</button>
						<button type="reset" class="layui-btn layui-btn-primary">重置</button>
					</div>
				</div>
			</form>
		</div>
	</div>
	<!-- 添加↑ -->
	<!-- 编辑↓ -->
	<div id="edit_div" class="modal hide main">
		<button class="layui-btn layui-btn-sm layui-btn-normal cancel">
			<i class="layui-icon"> 返回</i>
		</button>
		<fieldset class="layui-elem-field layui-field-title site-title">
			<legend>
				<a name="use"> 编辑角色 </a>
			</legend>
		</fieldset>
		<div class="site-text site-block">
			<form id="edit_form">
				<input type="hidden" name="id">
				<div class="layui-form-item">
					<label class="layui-form-label">角色名称</label>
					<div class="layui-input-inline">
						<input type="text" check="角色名称" name="name" placeholder="请输入角色名称"
							maxlength="16" autocomplete="off" class="layui-input">
					</div>
					<div class="layui-form-mid layui-word-aux">*</div>
				</div>
				<div class="layui-form-item">
					<label class="layui-form-label">类型</label>
					<div class="layui-input-inline">
						<input type="text" check="类型-int" name="type" placeholder="请输入类型"
							maxlength="8" autocomplete="off" class="layui-input">
					</div>
					<div class="layui-form-mid layui-word-aux">*</div>
				</div>
				<div class="layui-form-item">
					<label class="layui-form-label">描述</label>
					<div class="layui-input-inline">
						<textarea class="layui-textarea" name="description" maxlength="255"></textarea>
					</div>
					<div class="layui-form-mid layui-word-aux">*</div>
				</div>

				<div class="layui-form-item">
					<div class="layui-input-block">
						<button type="button" class="layui-btn active" id="submit_btn_e">立即提交</button>
					</div>
				</div>
			</form>
		</div>
	</div>
	<!-- 编辑↑ -->

	<!-- 工具栏  -->
	<div id="toolBar" style="display: none;">
		<a class="layui-btn layui-btn-disabled layui-btn-xs view_btn">查看</a> <a
			class="layui-btn layui-btn-xs edit_btn">编辑</a> <a
			class="layui-btn layui-btn-danger layui-btn-xs del_btn">删除</a>
	</div>
	
	<!-- 菜单树 -->
	<div id="tree_div" class="modal hide layui-btn-group">
			<button class="layui-btn layui-btn-sm layui-btn-normal cancel">
				<i class="layui-icon"> 返回</i>
			</button>
			<button class="layui-btn layui-btn-sm"   onclick="submitTree();">
				<i class="layui-icon"> 授权</i>
			</button>
		<div class="widget-body">
			<div class="widget-main	">
				<ul id="menuTree" class="ztree">
				</ul>
			</div>
		</div>
	</div>

	<script src="../../static/layui/layui.js"></script>
	<script src="../../static/modules/common.js"></script>
	<script src="../../static/jquery/1.9.1/jquery.min.js"></script>
	<script type="text/javascript" src="../../static/modules/zUtil.js"></script>
	<script type="text/javascript" src="role.js"></script>
	<script type="text/javascript" src="../../static/tree/jquery.ztree.all.js"></script>
	<script type="text/javascript" src="role_permission_tree.js"></script>
</body>
</html>